package com.ceshiren.hogwarts.wework;

import io.appium.java_client.AppiumDriver;
import org.openqa.selenium.By;

public class AppupExceptionHandler extends ExceptionHandler {
    @Override
    public Boolean isHit(String pageSource) {
        return pageSource.contains("确定");
    }

    @Override
    public void handle(AppiumDriver driver) {
        driver.findElement(By.xpath("//*[@text='确定']")).click();
    }
}
